package com.gxa.dao;

import com.gxa.pojo.Operation;
import org.apache.ibatis.annotations.Delete;
import org.apache.ibatis.annotations.Insert;
import org.apache.ibatis.annotations.Select;
import org.springframework.stereotype.Repository;

import java.util.List;

@Repository
public interface OperationMapper {
@Select("select * from operation ")
 //   public int selectOperation(Operation operation);
public List<Operation> selectOperation();
    /**
     * @param operation_type
     * @return
     */
    @Delete("delete  from operation where operation_name=#{operation_name}")
    public int deleteOperation(String operation_type);


    @Insert("insert into operation values (#{operation_resource}, #{operation_type},#{operation_name},#{operation_ip},#{operation_describe},#{operation_operate},#{operation_result},#{operation_time}")
    public int insertOperation(Operation operation);
}
